import { defineStore } from 'pinia';

import { getCityAll } from '@/service/modules/city';

 const useCityStore = defineStore('city', {
    

        state:()=>({
            allCities:{},
            currentCity:{
                cityName:"杭州"
            }
        }),
        actions:{
           async fetchAllCitiesData(){
                const res = await getCityAll()
                console.log(res,"pinia测试");
                this.allCities = res.data
            }
        }
});
export default useCityStore